package com.qijian.maindata.domain;

import java.math.BigDecimal;
import java.util.Date;

import com.baomidou.mybatisplus.annotation.TableId;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.qijian.common.enums.ApprovalDescriptionEnum;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.ToString;

import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import com.qijian.common.annotation.Excel;
import com.qijian.common.core.domain.BaseEntity;

/**
 * 工艺绩效-流程明细对象 main_process_performance_flow_detail
 *
 * @author qijian
 * @date 2024-05-24
 */
@EqualsAndHashCode(callSuper = true)
@Data
@ToString
@TableName("main_process_performance_flow_detail")
public class ProcessPerformanceFlowDetail extends BaseEntity{
    private static final long serialVersionUID = 1L;

    @TableId
    @JsonSerialize(using= ToStringSerializer.class)
    @ApiModelProperty(value = "ID")
    private Long workId;

    @Excel(name = "流程主表id")
    @JsonSerialize(using= ToStringSerializer.class)
    @ApiModelProperty(value = "流程主表id")
    private Long mainId;

    @Excel(name = "关联bom")
    @JsonSerialize(using= ToStringSerializer.class)
    @ApiModelProperty(value = "关联bom")
    private Long bomId;

    @Excel(name = "开工令号")
    @ApiModelProperty(value = "开工令号")
    private String projectNo;

    @Excel(name = "用户ID")
    @JsonSerialize(using= ToStringSerializer.class)
    @ApiModelProperty(value = "用户ID")
    private Long manageUserId;

    @Excel(name = "用户姓名")
    @ApiModelProperty(value = "用户姓名")
    private String manageNickName;

    @Excel(name = "部门id")
    @JsonSerialize(using= ToStringSerializer.class)
    @ApiModelProperty(value = "部门id")
    private Long manageDeptId;

    @Excel(name = "部门名称")
    @ApiModelProperty(value = "部门名称")
    private String manageDeptName;

    @Excel(name = "工单编号")
    @ApiModelProperty(value = "工单编号")
    private String workCode;

    @Excel(name = "物料ID")
    @JsonSerialize(using= ToStringSerializer.class)
    @ApiModelProperty(value = "物料ID")
    private Long itemId;

    @Excel(name = "物料名称")
    @ApiModelProperty(value = "物料名称")
    private String itemName;

    @Excel(name = "工序名称")
    @ApiModelProperty(value = "工序名称")
    private String processName;

    @Excel(name = "派工类型")
    @ApiModelProperty(value = "派工类型")
    private String workType;

    @Excel(name = "数量")
    @ApiModelProperty(value = "数量")
    private Long workNumber;

    @Excel(name = "工序工时")
    @ApiModelProperty(value = "工序工时")
    private BigDecimal workTime;

    @Excel(name = "工序工价")
    @ApiModelProperty(value = "工序工价")
    private BigDecimal workCost;

    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "开始时间", width = 30, dateFormat = "yyyy-MM-dd")
    @ApiModelProperty(value = "开始时间")
    private Date workStartTime;

    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "结束时间", width = 30, dateFormat = "yyyy-MM-dd")
    @ApiModelProperty(value = "结束时间")
    private Date workEndTime;

    @Excel(name = "状态", readConverterExp = "0=-完成，1-待派发，2-处理中")
    @ApiModelProperty(value = "状态（0-完成，1-待派发，2-处理中）")
    private Long status;

    @Excel(name = "备注")
    @ApiModelProperty(value = "备注")
    private String remark;

    @Excel(name = "作业人员id")
    @JsonSerialize(using= ToStringSerializer.class)
    @ApiModelProperty(value = "作业人员id")
    private Long userId;

    @Excel(name = "作业人员名称")
    @ApiModelProperty(value = "作业人员名称")
    private String nickName;

    @Excel(name = "作业工时")
    @ApiModelProperty(value = "作业工时")
    private BigDecimal times;

    @Excel(name = "作业工价")
    @ApiModelProperty(value = "作业工价")
    private BigDecimal prices;

    @Excel(name = "作业人部门id")
    @JsonSerialize(using= ToStringSerializer.class)
    @ApiModelProperty(value = "作业人部门id")
    private Long deptId;

    @Excel(name = "作业人部门")
    @ApiModelProperty(value = "作业人部门")
    private String deptName;

    @Excel(name = "实际工时")
    @ApiModelProperty(value = "实际工时")
    private BigDecimal acutalTimes;

    @Excel(name = "产品名称")
    @ApiModelProperty(value = "产品名称")
    private String productName;

    @Excel(name = "创建人id")
    @JsonSerialize(using= ToStringSerializer.class)
    @ApiModelProperty(value = "创建人id")
    private Long createId;

}
